<?php
    echo "<html>";
    echo "<head><title>Update to SVN Version</title>";
    echo "</head>";
	echo "UpdateFromSVN.php v1.0<br/>";
	$SERVER_NAME = $_SERVER["SERVER_NAME"];
	$IP = gethostbyname ($SERVER_NAME);
	$server = gethostbyaddr($IP);
	echo "<br/>Server IP: $IP";
	echo "<br/>Server Name: $server";
	echo "<br/><br/>Running as: ";
	passthru("/usr/bin/whoami", $retval);
	echo "<br/>Running where: ";
	passthru("pwd", $retval);	echo "<br/><br/>";

// Before using this script, you must edit the updatefromsvn.sh file that is in the same subdirectory.
// Once you have edited that file, you can then:
//
// Comment these lines:
//	echo '<br/>';
//	echo 'The file "updatefromsvn.sh" has not yet been edited and configured!<br/>';
//	echo 'Make the changes to that file, then edit this file and comment/uncomment the appropriate lines!<br/>';
//	echo '<br/><br/>';

// And Uncomment these lines:
	echo '<form action="updateToSVNRevision.php" method="post">';
	echo "This script will Deploy to the server based on the SVN Revision number ...<br><br>";
	echo 'Enter the SVN Revision Number: <input type="text" value="head" name="rev" /><br>';
	echo '<br><input type="submit" value="Deploy!" />';
	echo "</form>";

	phpinfo();
?>
